﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI.WebControls;

/// <summary>
/// Summary description for Class1
/// </summary>

public static class Extensions {
    public static IEnumerable<ListItem> GetSelectedItems(this ListItemCollection items) {
        return items.OfType<ListItem>().Where(item => item.Selected);
    }
}
